home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1999 May: Tool Chest / Developer CD Series Tool Chest (Apple Computer)(May 1999).iso / Tool Chest / Devices / CD-ROM / iso9660 / iso9660.r < prev    next >
Encoding:
Text File  |  1995-09-28  |  8.0 KB  |  370 lines  |  [TEXT/MPS ]

  1. /*
  2. ** Demonstration rez input file for ISO 9660 builder.
  3. ** To build the resources for this program, enter the command
  4. **    rez iso9660.r -i {rincludes}  -o iso9660.π.rsrc -c 'RSED' -t 'rsrc'
  5. **
  6. ** Copyright © 1990 Apple Computer, Inc.
  7. */
  8.  
  9. #include "types.r"
  10. #include "systypes.r"
  11.  
  12. type '9660' {pstring;};
  13.  
  14. type 'TEXT' {string;};
  15.  
  16. resource 'DITL' (128) {
  17.     {    /* array DITLarray: 4 elements */
  18.         /* [1] */
  19.         {152, 128, 173, 228},
  20.         Button {
  21.             enabled,
  22.             "OK"
  23.         },
  24.         /* [2] */
  25.         {8, 101, 26, 259},
  26.         StaticText {
  27.             disabled,
  28.             "ISO 9660 Demo Builder"
  29.         },
  30.         /* [3] */
  31.         {31, 105, 48, 253},
  32.         StaticText {
  33.             disabled,
  34.             "Author: Brian Bechtel"
  35.         },
  36.         /* [4] */
  37.         {56, 23, 135, 331},
  38.         StaticText {
  39.             disabled,
  40.             "Version 1.1. This demonstration program is copyright © 1990-1994 Apple Computer, Inc.  "
  41.             "Please select help for further information."
  42.         }
  43.     }
  44. };
  45.  
  46.  
  47. resource 'DITL' (256) {
  48.     {    /* array DITLarray: 4 elements */
  49.         /* [1] */
  50.         {72, 24, 92, 83},
  51.         Button {
  52.             enabled,
  53.             "OK"
  54.         },
  55.         /* [2] */
  56.         {72, 96, 92, 156},
  57.         Button {
  58.             enabled,
  59.             "Cancel"
  60.         },
  61.         /* [3] */
  62.         {48, 24, 64, 258},
  63.         EditText {
  64.             enabled,
  65.             "Your Name Here"
  66.         },
  67.         /* [4] */
  68.         {8, 24, 40, 256},
  69.         StaticText {
  70.             disabled,
  71.             "^0"
  72.         }
  73.     }
  74. };
  75.  
  76. resource 'DITL' (257) {
  77.     {    /* array DITLarray: 4 elements */
  78.         /* [1] */
  79.         {106, 134, 126, 194},
  80.         Button {
  81.             enabled,
  82.             "Cancel"
  83.         },
  84.         /* [2] */
  85.         {104, 37, 124, 97},
  86.         Button {
  87.             enabled,
  88.             "OK"
  89.         },
  90.         /* [3] */
  91.         {6, 59, 87, 237},
  92.         StaticText {
  93.             enabled,
  94.             "Really format volume “^0”?  \n"
  95.             "This will destroy all data currently on this disk."
  96.         },
  97.         /* [4] */
  98.         {6, 17, 38, 49},
  99.         Icon {
  100.             enabled,
  101.             1
  102.         }
  103.     }
  104. };
  105.  
  106. resource 'DITL' (258) {
  107.     {    /* array DITLarray: 1 elements */
  108.         /* [1] */
  109.         {17, 36, 96, 180},
  110.         StaticText {
  111.             enabled,
  112.             "Please insert a floppy disk to be formatted as an ISO 9660 volume."
  113.         }
  114.     }
  115. };
  116.  
  117. resource 'DLOG' (257) {
  118.     {40, 40, 184, 280},
  119.     dBoxProc,
  120.     visible,
  121.     noGoAway,
  122.     0x0,
  123.     257,
  124.     "Verify Destruction"
  125. };
  126.  
  127. resource 'DLOG' (258) {
  128.     {40, 40, 148, 256},
  129.     altDBoxProc,
  130.     visible,
  131.     goAway,
  132.     0x0,
  133.     258,
  134.     "Prompt for a floppy"
  135. };
  136. resource 'DITL' (129) {
  137.     {    /* array DITLarray: 2 elements */
  138.         /* [1] */
  139.         {94, 79, 114, 139},
  140.         Button {
  141.             enabled,
  142.             "OK"
  143.         },
  144.         /* [2] */
  145.         {8, 16, 76, 209},
  146.         StaticText {
  147.             disabled,
  148.             "^0^1^2^3"
  149.         }
  150.     }
  151. };
  152.  
  153. data 'DITL' (1001, "help", purgeable) {
  154.     $"0002 0000 0000 00EE 00C3 0102 00FF 0402"            /* .........√...... */
  155.     $"4F4B 0000 0000 000B 0194 00E1 01A4 8002"            /* OK.......î...§Ä. */
  156.     $"0000 0000 0000 000B 000F 00E1 0195 8002"            /* .............ïÄ. */
  157.     $"0001"                                               /* .. */
  158. };
  159.  
  160. resource 'DLOG' (256) {
  161.     {78, 124, 180, 406},
  162.     altDBoxProc,
  163.     visible,
  164.     noGoAway,
  165.     0x0,
  166.     256,
  167.     "AskForVolume"
  168. };
  169.  
  170. resource 'DLOG' (1001, "Help") {
  171.     {34, 42, 305, 472},
  172.     dBoxProc,
  173.     invisible,
  174.     noGoAway,
  175.     0x0,
  176.     1001,
  177.     "Help"
  178. };
  179.  
  180. resource 'MENU' (128) {
  181.     128,
  182.     textMenuProc,
  183.     0x7FFFFFFD,
  184.     enabled,
  185.     apple,
  186.     {    /* array: 2 elements */
  187.         /* [1] */
  188.         "About iso9660...", noIcon, noKey, noMark, plain,
  189.         /* [2] */
  190.         "-", noIcon, noKey, noMark, plain
  191.     }
  192. };
  193.  
  194. resource 'MENU' (129) {
  195.     129,
  196.     textMenuProc,
  197.     0x7FFFFFFB,
  198.     enabled,
  199.     "File",
  200.     {    /* array: 8 elements */
  201.         /* [1] */
  202.         "Help", noIcon, "H", noMark, plain,
  203.         /* [2] */
  204.         "Specify files for root…", noIcon, noKey, noMark, plain,
  205.         /* [3] */
  206.         "-", noIcon, noKey, noMark, plain,
  207.         /* [4] */
  208.         "Quit", noIcon, "Q", noMark, plain
  209.     }
  210. };
  211.  
  212. resource 'MENU' (130) {
  213.     130,
  214.     textMenuProc,
  215.     0x7FFFFFFC,
  216.     enabled,
  217.     "Edit",
  218.     {    /* array: 6 elements */
  219.         /* [1] */
  220.         "Undo", noIcon, "Z", noMark, plain,
  221.         /* [2] */
  222.         "-", noIcon, noKey, noMark, plain,
  223.         /* [3] */
  224.         "Cut", noIcon, "X", noMark, plain,
  225.         /* [4] */
  226.         "Copy", noIcon, "C", noMark, plain,
  227.         /* [5] */
  228.         "Paste", noIcon, "V", noMark, plain,
  229.         /* [6] */
  230.         "Clear", noIcon, noKey, noMark, plain
  231.     }
  232. };
  233.  
  234. resource 'ICN#' (128) {
  235.     {    /* array: 2 elements */
  236.         /* [1] */
  237.         $"0000 0000 0000 0000 0000 0000 007F 0000"
  238.         $"01D5 E000 06AA B000 0D55 5800 1AAA AC00"
  239.         $"3555 5600 2AAA AB00 557F 5500 6AC1 AB80"
  240.         $"D59C D5C0 AB3E 6AC0 D571 55C0 AB61 6AC0"
  241.         $"D561 3FC0 AB22 40C0 D59C 8040 6AC1 3020"
  242.         $"5561 C81E 2ABE 3F8E 3556 300E 1AAB 000E"
  243.         $"0D55 800E 06AA C00E 03D5 FFCE 00FF E03E"
  244.         $"003F 80",
  245.         /* [2] */
  246.         $"0000 0000 0000 0000 0000 0000 007F 0000"
  247.         $"01FF E000 07FF F000 0FFF F800 1FFF FC00"
  248.         $"3FFF FE00 3FFF FF00 7FFF FF00 7FFF FF80"
  249.         $"FFFF FFC0 FFFF FFC0 FFFF FFC0 FFFF FFC0"
  250.         $"FFFF FFC0 FFFF FFC0 FFFF FFC0 7FFF FFE0"
  251.         $"7FFF FFFE 3FFF FFFE 3FFF FFFE 1FFF FFFE"
  252.         $"0FFF FFFE 07FF FFFE 03FF FFFE 00FF E03E"
  253.         $"003F 80"
  254.     }
  255. };
  256.  
  257. resource 'BNDL' (128) {
  258.     '9660',
  259.     0,
  260.     {    /* array TypeArray: 2 elements */
  261.         /* [1] */
  262.         'ICN#',
  263.         {    /* array IDArray: 1 elements */
  264.             /* [1] */
  265.             0, 128
  266.         },
  267.         /* [2] */
  268.         'FREF',
  269.         {    /* array IDArray: 1 elements */
  270.             /* [1] */
  271.             0, 128
  272.         }
  273.     }
  274. };
  275.  
  276. resource '9660' (0) {
  277.     "ISO 9660 floppy builder 1.1 © 1990 Apple Computer, Inc."
  278. };
  279.  
  280. resource 'FREF' (128) {
  281.     'APPL',
  282.     0,
  283.     ""
  284. };
  285.  
  286. resource 'ALRT' (128, purgeable) {
  287.     {58, 76, 248, 420},
  288.     128,
  289.     {    /* array: 4 elements */
  290.         /* [1] */
  291.         OK, visible, silent,
  292.         /* [2] */
  293.         OK, visible, silent,
  294.         /* [3] */
  295.         OK, visible, silent,
  296.         /* [4] */
  297.         OK, visible, silent
  298.     }
  299. };
  300.  
  301. resource 'ALRT' (129) {
  302.     {66, 84, 214, 316},
  303.     129,
  304.     {    /* array: 4 elements */
  305.         /* [1] */
  306.         OK, visible, silent,
  307.         /* [2] */
  308.         OK, visible, silent,
  309.         /* [3] */
  310.         OK, visible, silent,
  311.         /* [4] */
  312.         OK, visible, silent
  313.     }
  314. };
  315.  
  316. resource 'TEXT' (1001, "help text") {
  317.     "ISO 9660 floppy builder\n\n"
  318.     "a demonstration program for building ISO 9660 format disks.\n\n"
  319.     "The ISO 9660 floppy builder builds disks conforming to the international standard "
  320.     "“ISO 9660 Information processing — "
  321.     "Volume and file structure of CD-ROM for information interchange.”  "
  322.     "This program has a number of features.  They are listed below.  "
  323.     "The bracketed number after each feature indicates the section in the ISO 9660 document "
  324.     "that describes this feature.\n\n"
  325.     "•    Assumes that the logical sector size is 2048 [6.1.2]\n"
  326.     "•    Assumes that the logical block size is 2048 [6.2.2]\n"
  327.     "•    Writes a primary volume descriptor [8.4]\n"
  328.     "•    Writes a volume descriptor set terminator [8.3]\n"
  329.     "•    supports the “Apple Extensions to ISO 9660” (documented in a separate paper "
  330.     "available from Apple Computer as part of Apple Technical Report 16, "
  331.     "available on the Developer CD as the document 'CD-ROM and the Macintosh Computer')\n"
  332.     "•    allows the user to specify a volume name.  "
  333.     "The volume name is automatically converted to the proper character subset [8.4.6]\n"
  334.     "•    lets the user choose, via a standard file dialog, files to be added to the ISO 9660 disk.  "
  335.     "All files are currently in the root directory.\n"
  336.     "•    both the resource fork and data fork of a file are copied to the disk.  "
  337.     "The resource fork is stored as the associated file.\n"
  338.     "•    currently doesn’t allow more than one logical sector of directory records.\n\n"
  339.     "The ISO 9660 floppy builder is a demonstration program; it doesn’t do many of the difficult parts "
  340.     "of building an ISO 9660 format disk.  Specifically, it doesn’t support:\n\n"
  341.     "•    sub-directories (folders)\n"
  342.     "•  keeping the files in a directory in alphabetical order\n"
  343.     "•    a main directory whose total size exceeds 1 block of 2048 bytes.\n\n"
  344.     "This program does not build subdirectories, and does not alphabetize the file names"
  345.     "—you must keep track of their order yourself. \n\n"
  346.     "Start with a formatted blank floppy or hard disk.  We will unmount the disk as "
  347.     "part of the process of making it into a ISO 9660 format disk.  All data will be "
  348.     "lost from the disk specified.\n\n"
  349.     "Select “Specify Files for Root…” to put files into the root directory.\n\n"
  350.     "You’ll be asked for the names of the files to be copied over via a standard file dialog.  "
  351.     "When you’re done selecting file names, hit the ‘cancel’ button.\n\n"
  352.     "Changes in version 1.1: \n"
  353.     "• Fixed a bug reported by Hans-Martin Mosner (hmm@heeg.de) which prevented "
  354.     "Apple extensions from working correctly.\n"
  355.     "• Converted to Universal Includes so that this now builds correctly for PowerPC as well as 68K.\n\n"
  356.     "\0x00"
  357. };
  358.  
  359.  
  360. resource 'vers' (1) {
  361.     0x1,
  362.     0x1,
  363.     0x0,
  364.     0x0,
  365.     verUs,
  366.     "1.1",
  367.     "1.1 © 1990 Apple Computer, Inc."
  368. };
  369.  
  370.